﻿var tpl = [
'<% if (user) { %>\r\n',
    '<h2><%= user.name %></h2>',
'<% } %>'
];

var ejs = require('ejs');
var out = ejs.render(tpl.join(''), { user: { name: 'shijiucha' } });
console.log(out);